/*
 * @Author: jimma0312 jimma0312@outlook.com
 * @Date: 2023-07-14 22:17:55
 * @LastEditors: Ma YuChen
 * @LastEditTime: 2023-08-02 17:35:13
 * @FilePath: \video-repeater-ctl-mcu\LT86101UXE\lt_global.h
 * @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
 */
#ifndef LT_GLOBAL_H
#define LT_GLOBAL_H
#include <stdbool.h>
#include <stdint.h>
#include <systick.h>

typedef struct S_STEP_STRUCT
{
    /* data */
    uint8_t s_StageStep;
    uint8_t i;
    TICK s_lastTime;
    TICK g_delayusTime;
}STEP_INFO;


typedef struct S_LT_GLOBAL
{
unsigned long	g_ulCurrentTime;
uint32_t    chipNo;
uint32_t    i2c_periph;
uint32_t	s_ulPreTmdsClock;
uint8_t		g_ucRxHdmi5vStatus;
uint8_t		uOldTxPlugStatus[1];
uint8_t		g_ucTxPlugNumber;
uint8_t          RX_OFFSET_VAL[3];
uint8_t 		data_received[2];
uint8_t 		data_num ;
uint8_t 		received;
bool		g_bFlagSystemStart;
bool		bFlagHdmi20;
bool		FlagStartWork;
bool		g_bFlagHdmi20True;
bool       Flag_HDMIVer_Changed;
bool        Flag_ClkStable;
bool		g_bFlagRxPllLock[3];
bool		g_Flag_Init_Finished;
bool		g_Systerm_start[3];
bool       g_Startstage_clr[3];
STEP_INFO   g_init_timer;
STEP_INFO   start_work_timer;
STEP_INFO   Clk_Stable_Cfg_timer;
STEP_INFO   printErr_timer;
}LT_GLOBAL;


extern void vdInitialGlobal(LT_GLOBAL* _lt_GlobalStruct );


#endif //LT_GLOBAL_H
